package cn.hxzy.common;

import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;

@AllArgsConstructor
@NoArgsConstructor
@Getter
public enum VoucherType {

    voucherType_01(101, "手动提货单"),
    voucherType_02(102, "自动提货单");

    private Integer voucherType;
    private String voucherTypeName;


    public static String getVoucherTypeValue(int index) {
        for (VoucherType value : VoucherType.values()) {
            if (value.getVoucherType() == index) {
                return value.getVoucherTypeName();
            }
        }
        return null;
    }
}
